#include "control.h"
#include "myconfig.h"
#define EXPAND_2(a,b,marker,c,...) {a,b,__VA_ARGS__},{a,c,__VA_ARGS__}
#define EXPAND_3(a,b,marker1,c,marker2,d,...) {a,b,__VA_ARGS__},{a,c,__VA_ARGS__},{a,d,__VA_ARGS__}
#define EXPAND_4(a,b,marker1,c,marker2,d,marker3,e,...) {a,b,__VA_ARGS__},{a,c,__VA_ARGS__},{a,d,__VA_ARGS__},{a,e,__VA_ARGS__}

#define DISTANCE_1_2 900//1到2的加速距离
#define DISTANCE_3_4 1000//3到4的加速距离
#define DISTANCE_3_5 300//3到5的加速距离
#define DISTANCE_5_6 1000//5到6的加速距离
#define DISTANCE_5_9 500 //5到9的加速距离
#define DISTANCE_5_7 4000//5到7的加速距离
#define DISTANCE_5_10 3200//5到10的加速距离
#define DISTANCE_5_12 DISTANCE_5_7 //5到12的加速距离
#define DISTANCE_6_7 2600//6到7的加速距离
#define DISTANCE_6_8 2600//6到8的加速距离
#define DISTANCE_6_9 2500//6到9的加速距离
#define DISTANCE_6_14 2000//6到14的加速距离
#define DISTANCE_6_41 500//6到41的加速距离
#define DISTANCE_6_42 800//6到42的加速距离
#define DISTANCE_6_13 1500//6到13的加速距离
#define DISTANCE_6_12 7200//6到12的加速距离
#define DISTANCE_7_12 10000//7到12的加速距离
#define DISTANCE_7_9 6900//7到9的加速距离
#define DISTANCE_8_6 1500//8到6的加速距离
#define DISTANCE_9_12 1200//9到12的加速距离
#define DISTANCE_9_13 1600//9到13的加速距离
#define DISTANCE_9_14 3600//9到14的加速距离
#define DISTANCE_9_15 2000//9到15的加速距离
#define DISTANCE_9_39 800//9到39的加速距离
#define DISTANCE_6_15 3500 //6到15的加速距离
#define DISTANCE_10_5 1000//10到5的加速距离
#define DISTANCE_10_7 5000//10到7的加速距离
#define DISTANCE_10_9 0//10到9的加速距离
#define DISTANCE_10_11 1200//10到11的加速距离
#define DISTANCE_10_12 800//10到12的加速距离
#define DISTANCE_12_10 350//12到10的加速距离
#define DISTANCE_13_15 1300//13到15的加速距离
#define DISTANCE_13_14 1000//13到14的加速距离
#define DISTANCE_13_40 200//13到40的加速距离
#define DISTANCE_13_41 200//13到41的加速距离
#define DISTANCE_14_15 600//14到15的加速距离 前后半段距离一样
#define DISTANCE_14_37 3600//14到15的加速距离 前后半段距离一样
#define DISTANCE_14_16 1700//14到16的加速距离
#define DISTANCE_14_17 3600//14到17的加速距离
#define DISTANCE_14_42 700//14到42的加速距离
#define DISTANCE_15_30 650//15到30的加速距离
#define DISTANCE_15_31 0//15到31的加速距离
#define DISTANCE_15_41 2300//15到41的加速距离
#define DISTANCE_15_37 2700 //15到37的加速距离
#define DISTANCE_15_39 500 //15到39的加速距离
#define DISTANCE_16_17 500 //16到17的加速距离
#define DISTANCE_17_18 0//17到18的加速距离
#define DISTANCE_17_20 1200//17到20的加速距离
#define DISTANCE_18_20 600//18到20的加速距离
#define DISTANCE_20_21 1000//20到21的加速距离
#define DISTANCE_21_22 600//21到22的加速距离
#define DISTANCE_22_23 1700//22到23的加速距离
#define DISTANCE_23_24 500//23到24的加速距离
#define DISTANCE_26_29 1000//26到29的加速距离
#define DISTANCE_25_28_before 1600//25到28的加速距离 前半段
#define DISTANCE_25_28_after 1800//25到28的加速距离 后半段
#define DISTANCE_30_50 1200//30到50的加速距离 前后半段距离一样


//以上用于下下个节点在同一条线上的情况，即只用写一次，扩展为多个,marker为任意字符，是分隔符
//例子：EXPAND_2(1,2,"or",3,...) 会扩展为{1,2,...},{1,3,...}
const linkInfoTypeDef mapInfo[NODE_NUM+1][NODE_FORK_NUM]={
/*节点示例*/{{0,0,FL_default,FREE,NOSpeed,0,SEEK_default,NoPark,HN_Rotate,0},//没有用到
            {1,2,}},
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 1*/ {
            {2,3,FL_middle,Platform_DOWN_ONE,AUTO_SPEED,DISTANCE_1_2,SEEK_NONE,NoPark,HN_Rotate,0},
            {2,5,FL_default,Platform_DOWN,NOSpeed,0,SEEK_default,NoPark,H_trace_l,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 2*/ {{1,2,FL_default,FREE,NOSpeed,0,SEEK_Platform,PARK_Platform_ONE,HN_Rotate,0},
            {3,4,FL_middle,BRIDGE,NOSpeed,0,SEEK_NONE,NoPark,HN_Rotate,0},
            {5,7,FL_middle,Wave_time,NOSpeed,0,SEEK_default,NoPark,H_trace_r,0},
            {5,12,FL_default,Wave_time,NOSpeed,0,SEEK_default,PARK_pesL,HL_135,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 3*/ {{4,3,FL_middle,FREE,AUTO_SPEED,DISTANCE_3_4,SEEK_Platform,PARK_Platform,HN_Rotate,0},
            EXPAND_2(5,7,"or",6,FL_middle,STEP,NOSpeed,0,SEEK_default,PARK_pesR,HR_135,0),
            EXPAND_2(5,10,"or",12,FL_middle,STEP,AUTO_SPEED,0,SEEK_middle,NoPark,H_trace_r,DISTANCE_3_5),
            {2,1,FL_middle,BRIDGE,NOSpeed,0,SEEK_default,NoPark,HN_Rotate,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
 /*Node 4*/ {{3,5,FL_middle,Platform_DOWN,NOSpeed,0,SEEK_remote,NoPark,H_trace_r,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 5*/ {{2,1,FL_middle,Wave_time,NOSpeed,0,SEEK_middle,NoPark,H_trace_r,0},
            {7,12,FL_middle,FREE,COMMON_SPEED,DISTANCE_5_7,SEEK_PesR,PARK_Platform,HN_Rotate,0},
            {7,6,FL_middle,FREE,COMMON_SPEED,DISTANCE_5_7,SEEK_Platform,PARK_Platform,HN_Rotate,0},
            EXPAND_3(12,10,"or",7,"or",5,FL_middle,FREE,AUTO_SPEED,DISTANCE_5_12,SEEK_Platform,PARK_Platform,HN_Rotate,0),
            {3,4,FL_middle,STEP,NOSpeed,0,SEEK_default,NoPark,H_trace_l,0},
            {6,8,FL_middle, FREE,AUTO_SPEED,DISTANCE_5_6,SEEK_middle,NoPark,H_trace_r,0},
            {10,11,FL_middle,FREE,AUTO_SPEED,DISTANCE_5_10,SEEK_middle,NoPark,H_trace_l,0},
            EXPAND_2(7,6,"or",9,FL_quick,FREE,COMMON_SPEED,DISTANCE_7_12/2,SEEK_Platform,PARK_Platform,HN_Rotate,0),
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 6*/ {{5,2,FL_middle,FREE,COMMON_SPEED,DISTANCE_5_6,SEEK_remote,NoPark,H_trace_l,0},
            {8,6,FL_middle,FREE,COMMON_SPEED,DISTANCE_6_8,SEEK_PesF,PARK_collide,HN_Rotate,0},
            {5,3,FL_default,FREE,NOSpeed,0,SEEK_default,PARK_pesL_300,HL_135,0},
            EXPAND_4(7,12,"or",5,"or",6,"or",9,FL_middle,FREE,AUTO_SPEED,DISTANCE_6_7,SEEK_Platform,PARK_Platform,HN_Rotate,0),
            {15,37,FL_middle,FREE,AUTO_SPEED,DISTANCE_6_15,SEEK_middle,NoPark,H_trace_l,0},
            {14,17},
				EXPAND_2(41,13,"or",15,FL_middle,FREE,AUTO_SPEED,DISTANCE_6_41,SEEK_default,DOOR,HN_Rotate,0),
            {42,14,FL_middle,FREE,COMMON_SPEED,DISTANCE_6_42,SEEK_default,DOOR,HN_Rotate,0},
            {9,39,FL_middle,FREE,COMMON_SPEED,DISTANCE_6_9,SEEK_middle,NoPark,HR_ARC_90,0},
            EXPAND_2(14,15,"or",37,FL_quick,FREE,COMMON_SPEED,DISTANCE_6_14,SEEK_default,PARK_pesR,HL_90,0),
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 7*/ {{6,8,FL_middle,Platform_DOWN,COMMON_SPEED,DISTANCE_6_7,SEEK_default,PARK_pesL_300,HL_135,0},
            EXPAND_3(6,41,"or",13,"or",15,FL_middle,Platform_DOWN,AUTO_SPEED,DISTANCE_6_7,SEEK_middle,NoPark,H_trace_r,0),
            EXPAND_2(12,10,"or",9,FL_middle,Platform_DOWN,COMMON_SPEED,DISTANCE_7_12,SEEK_Platform,PARK_Platform,HN_Rotate,0),
            {5,2,FL_middle,Platform_DOWN,COMMON_SPEED,DISTANCE_5_7,SEEK_middle,NoPark,H_trace_l,0},
            {6,14,FL_middle,Platform_DOWN,AUTO_SPEED,DISTANCE_6_7,SEEK_default,NoPark,HR_ARC_90,0},
            {9,15,FL_middle,Platform_DOWN,COMMON_SPEED,DISTANCE_7_9,SEEK_middle,NoPark,HR_ARC_90,0},
            {9,13,FL_quick,Platform_DOWN,COMMON_SPEED,DISTANCE_7_9,SEEK_remote,NoPark,HR_ARC_120,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 8*/ {{6,5,FL_default,FREE,COMMON_SPEED,DISTANCE_6_8,SEEK_default,NoPark,H_trace_l,0},
            {6,7,FL_Reversing,FREE,COMMON_Back_SPEED,DISTANCE_6_8,SEEK_NONE,PARK_pesL_Back_200,HL_15,0},
            EXPAND_3(6,41,"or",13,"or",15,FL_middle,Platform_DOWN,COMMON_SPEED,DISTANCE_8_6,SEEK_default,NoPark,H_trace_l,0),
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 9*/ {{5,2,FL_middle,FREE,AUTO_SPEED,DISTANCE_5_9,SEEK_remote,NoPark,HR_ARC_150,0},
            {15,37,FL_middle,FREE,COMMON_SPEED,DISTANCE_9_15,SEEK_middle,NoPark,HL_ARC_90,0},
            {14,17},//未实现
            {39,15,FL_middle,FREE,COMMON_SPEED,DISTANCE_9_39,SEEK_default,DOOR,HN_Rotate,0},
            EXPAND_2(40,13,"or",14,FL_middle,FREE,COMMON_SPEED,600,SEEK_default,DOOR,HN_Rotate,0),
            {6,41,FL_middle,FREE,COMMON_SPEED,2*DISTANCE_5_6,SEEK_default,PARK_pesL_300,HL_135,0},
            {13,15,FL_middle,FREE,COMMON_SPEED,DISTANCE_9_13,SEEK_remote,NoPark,HL_ARC_90,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 10*/ {{11,10,FL_quick,FREE,COMMON_SPEED,DISTANCE_10_11,SEEK_PesF,PARK_collide,HN_Rotate,0},
            {7,6,FL_middle,FREE,COMMON_SPEED,DISTANCE_10_7,SEEK_Platform,PARK_Platform,HN_Rotate,0},
            {5,2,FL_default,FREE,COMMON_SPEED,DISTANCE_10_5,SEEK_default,PARK_pesR,HR_135,0},
            {5,3,FL_default,FREE,COMMON_SPEED,DISTANCE_10_5,SEEK_default,NoPark,H_trace_r,0},
            EXPAND_2(9,15,"or",39,FL_middle,FREE,COMMON_SPEED,DISTANCE_10_9,SEEK_middle,NoPark,HL_ARC_90,0),
            {12,6,FL_middle,FREE,AUTO_SPEED,DISTANCE_10_12,SEEK_Platform,PARK_Platform,HN_Rotate,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 11*/ {EXPAND_2(10,7,"or",9,FL_middle,FREE,COMMON_SPEED,DISTANCE_10_11,SEEK_default,NoPark,H_trace_r,0),
            {10,12,FL_Reversing,FREE,COMMON_Back_SPEED,DISTANCE_10_11,SEEK_NONE,PARK_pesR_Back,HR_30,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 12*/ {{10,11,FL_middle,Platform_DOWN,COMMON_SPEED,DISTANCE_12_10,SEEK_remote,NoPark,HR_ARC_150,0},
             EXPAND_2(9,39,"or",15,FL_middle,Platform_DOWN,COMMON_SPEED,DISTANCE_9_12,SEEK_middle,NoPark,HL_ARC_90),
             EXPAND_3(9,40,"or",13,"or",14,FL_middle,Platform_DOWN,COMMON_SPEED,DISTANCE_9_12,SEEK_default,NoPark,H_trace_l),
             {6,8,FL_default,Platform_DOWN,COMMON_SPEED,DISTANCE_6_12,SEEK_default,NoPark,H_trace_r,0},
             EXPAND_2(7,6,"or",9,FL_quick,Platform_DOWN,COMMON_SPEED,DISTANCE_7_12,SEEK_Platform,PARK_Platform,HN_Rotate,0),
             {5,7,FL_quick,Platform_DOWN,COMMON_SPEED,DISTANCE_7_12/2,SEEK_NONE,NoPark,HN_Rotate,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 13*/ {{15,37,FL_middle,FREE,COMMON_SPEED,DISTANCE_13_15,SEEK_middle,NoPark,H_trace_l,0},
             {9,5,FL_middle,FREE,COMMON_SPEED,DISTANCE_9_13,SEEK_default,PARK_pesR,HL_140,0},
             {6,5,FL_middle,FREE,COMMON_SPEED,DISTANCE_6_13,SEEK_remote,NoPark,HR_ARC_120,0},
             {15,14,FL_middle,FREE,COMMON_SPEED,DISTANCE_13_15,SEEK_default,PARK_pesR,HR_135,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 14*/ {{15,9,FL_middle,Wave_TWICE,COMMON_SPEED,DISTANCE_14_15-200,SEEK_middle,NoPark,HL_ARC_90,DISTANCE_14_15},
             {15,31,FL_middle,Wave_TWICE,COMMON_SPEED,DISTANCE_14_15,SEEK_default,PARK_pesR,HR_90,DISTANCE_14_15},
             {15,37,FL_middle,Wave_TWICE,COMMON_SPEED,DISTANCE_14_15,SEEK_default,PARK_pesR,HN_Rotate,DISTANCE_14_15},
             {6,5,FL_middle,FREE,COMMON_SPEED,DISTANCE_6_14,SEEK_middle,NoPark,HR_ARC_90,0},
             {13,9,FL_middle,FREE,COMMON_SPEED,DISTANCE_13_14,SEEK_default,PARK_pesR,HN_Rotate,0},
             {13,6,FL_middle,FREE,COMMON_SPEED,DISTANCE_13_14,SEEK_middle,NoPark,HL_ARC_110,0},
             {9,5,FL_quick,FREE,COMMON_SPEED,DISTANCE_9_14,SEEK_remote,NoPark,HL_ARC_130,0},
             {37,15,FL_middle,Wave_TWICE,COMMON_SPEED,DISTANCE_14_37,SEEK_Platform,PARK_Platform,HN_Rotate,DISTANCE_14_15}
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 15*/ {{37,15,FL_middle,FREE,AUTO_SPEED,DISTANCE_15_37,SEEK_Platform,PARK_Platform,HN_Rotate,0},
             {30,50,FL_middle,FREE,COMMON_SPEED,DISTANCE_15_30,SEEK_middle,NoPark,HL_ARC_90,0},
             {9,5,FL_middle,FREE,COMMON_SPEED,DISTANCE_9_15,SEEK_middle,NoPark,HL_ARC_90,0},
             {31,32,FL_quick,FREE,COMMON_SPEED,DISTANCE_15_31,SEEK_default,PARK_pesR,HR_90,0},
             {14,6,FL_middle,FREE,COMMON_SPEED,DISTANCE_14_15,SEEK_default,PARK_pesR_300,HR_90,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 16*/ {{44,45,FL_Arc,ARC_16_44,COMMON_SPEED,0,SEEK_NONE,NoPark,HN_Rotate,0},
             {14,15,FL_middle,FREE,AUTO_SPEED,DISTANCE_14_16,SEEK_default,PARK_pesL,HN_Rotate,0},
             {14,13,FL_middle,FREE,COMMON_SPEED,DISTANCE_14_16,SEEK_middle,NoPark,H_trace_l,0},
             {14,6,FL_middle,FREE,COMMON_SPEED,DISTANCE_14_16,SEEK_middle,NoPark,HL_ARC_90,0},
             {15,9,FL_middle,Wave_TWICE,COMMON_SPEED,DISTANCE_14_15,SEEK_middle,NoPark,HL_ARC_90,3100},
             {14,9,FL_middle,FREE,AUTO_SPEED,DISTANCE_14_16,SEEK_middle,NoPark,H_trace_l,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 17*/ {{14,15,FL_middle,FREE,AUTO_SPEED,DISTANCE_14_17,SEEK_default,PARK_pesR,HN_Rotate,0},
             {14,6,FL_middle,FREE,AUTO_SPEED,DISTANCE_14_17,SEEK_middle,NoPark,HL_ARC_90,0},
             {14,13,FL_default,FREE,AUTO_SPEED,DISTANCE_14_17,SEEK_default,NoPark,H_trace_l,0},
             {14,9,FL_middle,FREE,AUTO_SPEED,DISTANCE_14_17,SEEK_default,NoPark,H_trace_l,0},
             {16,44,FL_middle,FREE,AUTO_SPEED,DISTANCE_16_17,SEEK_default,NoPark,HN_Rotate,0},
             EXPAND_2(16,14,"or",15,FL_middle,FREE,COMMON_SPEED,500,SEEK_default,NoPark,HN_Rotate,0),
             {15,9,FL_middle,Wave_TWICE,COMMON_SPEED,100,SEEK_middle,NoPark,HL_ARC_90,DISTANCE_14_17+DISTANCE_14_15},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 18*/ {{19,18,FL_default,FREE,COMMON_SPEED,0,SEEK_PesF,PARK_collide,HN_Rotate,0},
             EXPAND_3(17,14,"or",16,"or",15,FL_quick,FREE,COMMON_SPEED,DISTANCE_17_18,SEEK_middle,NoPark,HR_ARC_90,0),
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 19*/ {{18,17,NFL_GYRO_BACK,FREE,NOSpeed,0,SEEK_PesL,NoPark,HL_90,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 20*/ {{17,14,FL_middle,BLACK_UP,COMMON_SPEED,DISTANCE_17_20,SEEK_middle,NoPark,HR_ARC_90,0},
             {18,19,FL_middle,BLACK_UP,COMMON_SPEED,DISTANCE_18_20,SEEK_default,PARK_pesR,HR_90,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 21*/ {{20,17,FL_middle,FREE,AUTO_SPEED,DISTANCE_20_21,SEEK_default,PARK_pesR,HR_90,0},
             {20,18,FL_middle,FREE,AUTO_SPEED,DISTANCE_20_21,SEEK_remote,NoPark,HR_ARC_90,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 22*/ {{21,20,FL_middle,BLACK_UP,COMMON_SPEED,0,SEEK_middle,NoPark,HR_ARC_90,DISTANCE_21_22},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 23*/ {{24,23,FL_middle,PEAK,AUTO_SPEED,0,SEEK_NONE,PARK_Platform,HN_Rotate,0},
             {22,21,FL_middle,FREE,COMMON_SPEED,DISTANCE_22_23,SEEK_remote,NoPark,HL_ARC_120,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 24*/ {{23,22,FL_middle,PEAK_DOWN,COMMON_SPEED,0,SEEK_remote,NoPark,HL_ARC_150,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 25*/ {
#if GAME_MAP == FIND_TREASURE
             {26,29,FL_middle,FREE,NOSpeed,150,SEEK_default,NoPark,HL_ARC_90,0},
             {23,24,FL_middle,FREE,COMMON_SPEED,1700,SEEK_default,NoPark,HN_Rotate,0},
#endif
#if GAME_MAP == TRAVEL
             {26,29,FL_middle,FREE,NOSpeed,0,SEEK_middle,NoPark,HR_ARC_90,0},
#endif
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 26*/ {{29,27,FL_middle,Wave_TWICE,COMMON_SPEED,0,SEEK_NONE,NoPark,HN_Rotate,DISTANCE_26_29},
#if GAME_MAP == FIND_TREASURE
             {25,23,FL_middle,FREE,NOSpeed,0,SEEK_default,NoPark,HL_ARC_90,0},
#endif
#if GAME_MAP == TRAVEL
             {23,24,FL_middle,STEP,COMMON_SPEED,1200,SEEK_NONE,NoPark,HN_Rotate,1800},
#endif
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 27*/ {{29,26,FL_default,HILL_DOWN,NOSpeed,0,SEEK_NONE,NoPark,HN_Rotate,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 28*/ {
#if GAME_MAP == FIND_TREASURE
             {25,26,FL_middle,STEP,AUTO_SPEED,DISTANCE_25_28_after,SEEK_middle,NoPark,HL_ARC_90,DISTANCE_25_28_before},
#endif
#if GAME_MAP == TRAVEL
             {25,26,FL_middle,STEP,AUTO_SPEED,DISTANCE_25_28_after,SEEK_middle,NoPark,HR_ARC_90,DISTANCE_25_28_before},
#endif
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 29*/ {{27,29,FL_default,HILL,NOSpeed,0,SEEK_NONE,PARK_Platform,HN_Rotate,0},
#if GAME_MAP == FIND_TREASURE
			    {26,25,FL_middle,Wave_TWICE,AUTO_SPEED,DISTANCE_26_29,SEEK_middle,NoPark,HR_ARC_90,0},
#endif
#if GAME_MAP == TRAVEL             
             {26,23,FL_middle,Wave_TWICE,COMMON_SPEED,0,SEEK_NONE,NoPark,HN_Rotate,0},
#endif
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 30*/ {{50,28,FL_middle,STEP,AUTO_SPEED,DISTANCE_30_50,SEEK_middle,NoPark,HR_ARC_90,DISTANCE_30_50},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 31*/ {{32,31,FL_quick,FREE,COMMON_SPEED,0,SEEK_PesF,PARK_collide,HN_Rotate,0},
             {15,9,FL_middle,FREE,COMMON_SPEED,DISTANCE_15_31,SEEK_default,PARK_pesR,HN_Rotate,0},
             {30,50,FL_quick,FREE,COMMON_SPEED,0,SEEK_default,NoPark,HL_ARC_90,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 32*/ {{31,15,FL_middle,FREE,COMMON_SPEED,0,SEEK_default,PARK_pesR,HL_90,0},
             {31,30,NFL_GYRO_BACK,FREE,NOSpeed,0,SEEK_PesL,NoPark,HL_90,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 33*/ {{},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 34*/ {{},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 35*/ {{},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 36*/ {{},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 37*/ {EXPAND_2(15,31,"or",30,FL_middle,Platform_DOWN,AUTO_SPEED,DISTANCE_15_37,SEEK_middle,NoPark,HL_ARC_90,0),
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 38*/ {{},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 39*/ {EXPAND_2(9,40,"or",13,FL_Reversing,FREE,COMMON_Back_SPEED,DISTANCE_9_39,SEEK_NONE,PARK_pesR_Back,HR_45,0),
             {15,37,FL_middle,FREE,COMMON_SPEED,DISTANCE_15_39,SEEK_middle,NoPark,HL_ARC_90,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 40*/ {{13,15,FL_middle,FREE,COMMON_SPEED,DISTANCE_13_40,SEEK_default,PARK_pesL,HL_100,0},
             {9,6,FL_middle,FREE,NOSpeed,0,SEEK_default,PARK_pesL_300,HL_135,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 41*/ {{13,15,FL_middle,FREE,COMMON_SPEED,DISTANCE_13_41,SEEK_default,NoPark,HN_Rotate,0},
             {15,37,FL_middle,FREE,COMMON_SPEED,DISTANCE_15_41,SEEK_default,NoPark,H_trace_l,0},
				 {15,14,FL_middle,FREE,COMMON_SPEED,DISTANCE_15_41,SEEK_default,PARK_pesL,HR_135,0},
             {6,42,FL_Reversing,FREE,COMMON_Back_SPEED,DISTANCE_6_41,SEEK_NONE,PARK_pesR_Back,HR_60,0},
             {6,9,FL_Reversing,FREE,COMMON_Back_SPEED,DISTANCE_6_41,SEEK_NONE,PARK_pesL_Back,HL_45,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 42*/ {EXPAND_2(14,15,"or",37,FL_middle,FREE,COMMON_SPEED,DISTANCE_14_42,SEEK_middle,NoPark,HL_ARC_90,0),
             {14,6,FL_middle,FREE,COMMON_SPEED,0,SEEK_default,PARK_pesR,HL_180,0},
             {6,9,FL_Reversing,FREE,COMMON_Back_SPEED,DISTANCE_6_42-200,SEEK_NONE,PARK_pesL_Back,HL_90,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 43*/ {{48,16,FL_default,SEESAW,NOSpeed,0,SEEK_NONE,NoPark,HN_Rotate,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 44*/ {{45,46,FL_default,SEESAW,NOSpeed,0,SEEK_NONE,NoPark,HN_Rotate,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 45*/ {{46,47,FL_Arc,FREE,NOSpeed,0,SEEK_default,PARK_pesL,HL_90,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 46*/ {{47,46,FL_middle,FREE,NOSpeed,0,SEEK_Platform,PARK_Platform,HN_Rotate,0},
             {43,48,FL_Arc,ARC_16_44,COMMON_SPEED,0,SEEK_NONE,NoPark,HN_Rotate,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 47*/ {{46,43,FL_default,Platform_DOWN,NOSpeed,0,SEEK_default,PARK_pesR,HL_100,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 48*/ {{16,14,FL_Arc,FREE,NO_SPEED_TIME,400,SEEK_default,NoPark,H_trace_r,0},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 49*/ {{},
            },
            //下一节点号，下下节点号，寻线方法，障碍类型，加速类型，障碍后的 加速参数，找点方法，停车方法，旋转类型，障碍前的加速参数
/*Node 50*/ {
#if GAME_MAP == FIND_TREASURE   
   {28,25,FL_middle,FREE,AUTO_SPEED,300,SEEK_middle,NoPark,HR_ARC_90,0},
#endif
#if GAME_MAP == TRAVEL
   {28,25,FL_middle,BLACK_UP,COMMON_SPEED,0,SEEK_middle,NoPark,HR_ARC_90,800},
#endif
            },                                                                                                                                                            
};

bool isFindInGlobalMap(int now, int next, int nNext) {
  for (int i = 0; i < NODE_FORK_NUM; i++) {
    if (mapInfo[now][i].nextNode == next) {
      if (mapInfo[now][i].nextNextNode == nNext) {
        return true;
      }
    }
  }
  return false;
}